package com.acoffee.springcloud.common.entity;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;

/**
 * @author acoffee
 * @create 2022-01-19 17:25
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
public class ResponseEntity<T> {
    private int code;
    private String message;
    private T data;

    public ResponseEntity(int code, String message) {
        this.code = code;
        this.message = message;
    }
    public ResponseEntity(int code, T data) {
        this.code = code;
        this.data = data;
    }
}
